/*
ID: guoxu1
PROG: barn1
LANG: C++
*/
#include <iostream>
#include <fstream>
#include <vector>
#include <algorithm>
using namespace std;

#define cin fin
#define cout fout

int main()
{
  ifstream fin( "barn1.in" );
  ofstream fout( "barn1.out" );

  int boards = 0, stalls = 0, cows = 0;
  cin >> boards >> stalls >> cows;

  vector<int> poses;
  for( int i = 0; i < cows; i++ )
  {
    int pos = 0;
    cin >> pos;
    poses.push_back( pos );
  }

  std::sort( poses.begin(), poses.end() );

  int length = stalls;
  length -= ( *poses.begin() - 1 );
  length -= ( stalls - *poses.rbegin() );

  vector<int> intervals;
  for( int i = 1; i < cows; i++ )
  {
    intervals.push_back( poses[i] - poses[i - 1] - 1 );
  }
  std::sort( intervals.begin(), intervals.end(), std::greater<int>() );

  for( int i = 0; i < (int)intervals.size() && i < boards - 1; i++ )
  {
    length -= intervals[i];
  }

  cout << length << endl;
  return 0;
}
